<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<!-- @(#) $Id$ -->
<head>
<script type="text/javascript" src="wz_jsgraphics.js"></script>
</head>
<body>
</body>
<script type="text/javascript">
function genHex(){
colors = new Array(14)
colors[0]="0"
colors[1]="1"
colors[2]="2"
colors[3]="3"
colors[4]="4"
colors[5]="5"
colors[5]="6"
colors[6]="7"
colors[7]="8"
colors[8]="9"
colors[9]="a"
colors[10]="b"
colors[11]="c"
colors[12]="d"
colors[13]="e"
colors[14]="f"

digit = new Array(5)
color="0000"
for (x=0;x<2;x++){
 digit[x]=colors[Math.round(Math.random()*14)]
 color = color+digit[x]
}
return color;
}

function myDrawFunction() {
   jg_doc.setColor("#"+genHex());
  for (j = 10; j < 1500 ; j = j + 30) {
  for (i = 10; i < 1000 ; i = i + 15) {
   jg_doc.fillRect(j,i,28,13)
  jg_doc.paint(); // draws, in this case, directly into the document
  }
  }
}

var jg_doc = new jsGraphics(); // draw directly into document

myDrawFunction();
</script>
Just checking I have the correct document
</html>
		